﻿using System;
using System.Collections.Generic;
using System.Text;
using BlueFinity.mvNET.CoreObjects;
using IBMU2.UODOTNET;

namespace mvLibrary.Helpers.Querys
{
    public static class PickResultsFormatter
    {
        public static Dictionary<string, string> ItemListToDictionary(UniDynArray itemsList)
        {
            Dictionary<string, string> fileItems = new Dictionary<string, string>();

            for (int index = 1; index <= itemsList.Count(); ++index)
            {
                var key = itemsList.Extract(index, 1).ToString();
                var value = itemsList.Extract(index, 2).ToString();
                fileItems.Add(key, value);
            }

            return fileItems;
        }

    }
}
